3.1.65 \(\int \frac {\csc ^4(e+f x)}{(a+b \sec ^2(e+f x))^3} \, dx\) [65]

3.1.65.1 Optimal result
3.1.65.2 Mathematica [C] (warning: unable to verify)
3.1.65.3 Rubi [A] (verified)
3.1.65.4 Maple [A] (verified)
3.1.65.5 Fricas [B] (verification not implemented)
3.1.65.6 Sympy [F(-1)]
3.1.65.7 Maxima [B] (verification not implemented)
3.1.65.8 Giac [A] (verification not implemented)
3.1.65.9 Mupad [B] (verification not implemented)

3.1.65.1 Optimal result

Integrand size = 23, antiderivative size = 164 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^3} \, dx=-\frac {5 (3 a-4 b) \sqrt {b} \arctan \left (\frac {\sqrt {b} \tan (e+f x)}{\sqrt {a+b}}\right )}{8 (a+b)^{9/2} f}-\frac {(a-2 b) \cot (e+f x)}{(a+b)^4 f}-\frac {\cot ^3(e+f x)}{3 (a+b)^3 f}-\frac {a b \tan (e+f x)}{4 (a+b)^3 f \left (a+b+b \tan ^2(e+f x)\right )^2}-\frac {(7 a-4 b) b \tan (e+f x)}{8 (a+b)^4 f \left (a+b+b \tan ^2(e+f x)\right )} \]

output
-(a-2*b)*cot(f*x+e)/(a+b)^4/f-1/3*cot(f*x+e)^3/(a+b)^3/f-5/8*(3*a-4*b)*arc 
tan(b^(1/2)*tan(f*x+e)/(a+b)^(1/2))*b^(1/2)/(a+b)^(9/2)/f-1/4*a*b*tan(f*x+ 
e)/(a+b)^3/f/(a+b+b*tan(f*x+e)^2)^2-1/8*(7*a-4*b)*b*tan(f*x+e)/(a+b)^4/f/( 
a+b+b*tan(f*x+e)^2)
 
3.1.65.2 Mathematica [C] (warning: unable to verify)

Result contains complex when optimal does not.

Time = 5.03 (sec) , antiderivative size = 994, normalized size of antiderivative = 6.06 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^3} \, dx=\frac {(a+2 b+a \cos (2 (e+f x))) \sec ^6(e+f x) \left (\frac {480 (3 a-4 b) b \arctan \left (\frac {\sec (f x) (\cos (2 e)-i \sin (2 e)) (-((a+2 b) \sin (f x))+a \sin (2 e+f x))}{2 \sqrt {a+b} \sqrt {b (\cos (e)-i \sin (e))^4}}\right ) (a+2 b+a \cos (2 (e+f x)))^2 (\cos (2 e)-i \sin (2 e))}{\sqrt {a+b} \sqrt {b (\cos (e)-i \sin (e))^4}}-\frac {\csc (e) \csc ^3(e+f x) \sec (2 e) \left (4 \left (44 a^4+122 a^3 b+63 a^2 b^2+126 a b^3+36 b^4\right ) \sin (f x)+\left (-96 a^4-71 a^3 b+344 a^2 b^2-1208 a b^3+48 b^4\right ) \sin (3 f x)+224 a^4 \sin (2 e-f x)+576 a^3 b \sin (2 e-f x)+124 a^2 b^2 \sin (2 e-f x)-2184 a b^3 \sin (2 e-f x)+144 b^4 \sin (2 e-f x)-224 a^4 \sin (2 e+f x)-657 a^3 b \sin (2 e+f x)-538 a^2 b^2 \sin (2 e+f x)+984 a b^3 \sin (2 e+f x)+144 b^4 \sin (2 e+f x)+176 a^4 \sin (4 e+f x)+569 a^3 b \sin (4 e+f x)+666 a^2 b^2 \sin (4 e+f x)+1704 a b^3 \sin (4 e+f x)-144 b^4 \sin (4 e+f x)+48 a^4 \sin (2 e+3 f x)+111 a^3 b \sin (2 e+3 f x)+360 a^2 b^2 \sin (2 e+3 f x)+312 a b^3 \sin (2 e+3 f x)-48 b^4 \sin (2 e+3 f x)-96 a^4 \sin (4 e+3 f x)-152 a^3 b \sin (4 e+3 f x)+146 a^2 b^2 \sin (4 e+3 f x)-728 a b^3 \sin (4 e+3 f x)-48 b^4 \sin (4 e+3 f x)+48 a^4 \sin (6 e+3 f x)+192 a^3 b \sin (6 e+3 f x)+558 a^2 b^2 \sin (6 e+3 f x)-168 a b^3 \sin (6 e+3 f x)+48 b^4 \sin (6 e+3 f x)+16 a^4 \sin (2 e+5 f x)-598 a^2 b^2 \sin (2 e+5 f x)+48 a b^3 \sin (2 e+5 f x)+72 a^3 b \sin (4 e+5 f x)+150 a^2 b^2 \sin (4 e+5 f x)-48 a b^3 \sin (4 e+5 f x)+16 a^4 \sin (6 e+5 f x)+27 a^3 b \sin (6 e+5 f x)-388 a^2 b^2 \sin (6 e+5 f x)+45 a^3 b \sin (8 e+5 f x)-60 a^2 b^2 \sin (8 e+5 f x)+16 a^4 \sin (4 e+7 f x)-83 a^3 b \sin (4 e+7 f x)+6 a^2 b^2 \sin (4 e+7 f x)+27 a^3 b \sin (6 e+7 f x)-6 a^2 b^2 \sin (6 e+7 f x)+16 a^4 \sin (8 e+7 f x)-56 a^3 b \sin (8 e+7 f x)\right )}{a}\right )}{6144 (a+b)^4 f \left (a+b \sec ^2(e+f x)\right )^3} \]

input
Integrate[Csc[e + f*x]^4/(a + b*Sec[e + f*x]^2)^3,x]
 
output
((a + 2*b + a*Cos[2*(e + f*x)])*Sec[e + f*x]^6*((480*(3*a - 4*b)*b*ArcTan[ 
(Sec[f*x]*(Cos[2*e] - I*Sin[2*e])*(-((a + 2*b)*Sin[f*x]) + a*Sin[2*e + f*x 
]))/(2*Sqrt[a + b]*Sqrt[b*(Cos[e] - I*Sin[e])^4])]*(a + 2*b + a*Cos[2*(e + 
 f*x)])^2*(Cos[2*e] - I*Sin[2*e]))/(Sqrt[a + b]*Sqrt[b*(Cos[e] - I*Sin[e]) 
^4]) - (Csc[e]*Csc[e + f*x]^3*Sec[2*e]*(4*(44*a^4 + 122*a^3*b + 63*a^2*b^2 
 + 126*a*b^3 + 36*b^4)*Sin[f*x] + (-96*a^4 - 71*a^3*b + 344*a^2*b^2 - 1208 
*a*b^3 + 48*b^4)*Sin[3*f*x] + 224*a^4*Sin[2*e - f*x] + 576*a^3*b*Sin[2*e - 
 f*x] + 124*a^2*b^2*Sin[2*e - f*x] - 2184*a*b^3*Sin[2*e - f*x] + 144*b^4*S 
in[2*e - f*x] - 224*a^4*Sin[2*e + f*x] - 657*a^3*b*Sin[2*e + f*x] - 538*a^ 
2*b^2*Sin[2*e + f*x] + 984*a*b^3*Sin[2*e + f*x] + 144*b^4*Sin[2*e + f*x] + 
 176*a^4*Sin[4*e + f*x] + 569*a^3*b*Sin[4*e + f*x] + 666*a^2*b^2*Sin[4*e + 
 f*x] + 1704*a*b^3*Sin[4*e + f*x] - 144*b^4*Sin[4*e + f*x] + 48*a^4*Sin[2* 
e + 3*f*x] + 111*a^3*b*Sin[2*e + 3*f*x] + 360*a^2*b^2*Sin[2*e + 3*f*x] + 3 
12*a*b^3*Sin[2*e + 3*f*x] - 48*b^4*Sin[2*e + 3*f*x] - 96*a^4*Sin[4*e + 3*f 
*x] - 152*a^3*b*Sin[4*e + 3*f*x] + 146*a^2*b^2*Sin[4*e + 3*f*x] - 728*a*b^ 
3*Sin[4*e + 3*f*x] - 48*b^4*Sin[4*e + 3*f*x] + 48*a^4*Sin[6*e + 3*f*x] + 1 
92*a^3*b*Sin[6*e + 3*f*x] + 558*a^2*b^2*Sin[6*e + 3*f*x] - 168*a*b^3*Sin[6 
*e + 3*f*x] + 48*b^4*Sin[6*e + 3*f*x] + 16*a^4*Sin[2*e + 5*f*x] - 598*a^2* 
b^2*Sin[2*e + 5*f*x] + 48*a*b^3*Sin[2*e + 5*f*x] + 72*a^3*b*Sin[4*e + 5*f* 
x] + 150*a^2*b^2*Sin[4*e + 5*f*x] - 48*a*b^3*Sin[4*e + 5*f*x] + 16*a^4*...
 
3.1.65.3 Rubi [A] (verified)

Time = 0.45 (sec) , antiderivative size = 166, normalized size of antiderivative = 1.01, number of steps used = 8, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.304, Rules used = {3042, 4620, 361, 25, 1582, 1584, 2009}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^3} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {1}{\sin (e+f x)^4 \left (a+b \sec (e+f x)^2\right )^3}dx\)

\(\Big \downarrow \) 4620

\(\displaystyle \frac {\int \frac {\cot ^4(e+f x) \left (\tan ^2(e+f x)+1\right )}{\left (b \tan ^2(e+f x)+a+b\right )^3}d\tan (e+f x)}{f}\)

\(\Big \downarrow \) 361

\(\displaystyle \frac {-\frac {1}{4} b \int -\frac {\cot ^4(e+f x) \left (-\frac {3 a \tan ^4(e+f x)}{(a+b)^3}+\frac {4 a \tan ^2(e+f x)}{b (a+b)^2}+\frac {4}{b (a+b)}\right )}{\left (b \tan ^2(e+f x)+a+b\right )^2}d\tan (e+f x)-\frac {a b \tan (e+f x)}{4 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )^2}}{f}\)

\(\Big \downarrow \) 25

\(\displaystyle \frac {\frac {1}{4} b \int \frac {\cot ^4(e+f x) \left (-\frac {3 a \tan ^4(e+f x)}{(a+b)^3}+\frac {4 a \tan ^2(e+f x)}{b (a+b)^2}+\frac {4}{b (a+b)}\right )}{\left (b \tan ^2(e+f x)+a+b\right )^2}d\tan (e+f x)-\frac {a b \tan (e+f x)}{4 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )^2}}{f}\)

\(\Big \downarrow \) 1582

\(\displaystyle \frac {\frac {1}{4} b \left (\frac {\int \frac {\cot ^4(e+f x) \left (-\frac {(7 a-4 b) b^2 \tan ^4(e+f x)}{a+b}+8 (a-b) b \tan ^2(e+f x)+8 b (a+b)\right )}{b \tan ^2(e+f x)+a+b}d\tan (e+f x)}{2 b^2 (a+b)^3}-\frac {(7 a-4 b) \tan (e+f x)}{2 (a+b)^4 \left (a+b \tan ^2(e+f x)+b\right )}\right )-\frac {a b \tan (e+f x)}{4 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )^2}}{f}\)

\(\Big \downarrow \) 1584

\(\displaystyle \frac {\frac {1}{4} b \left (\frac {\int \left (8 b \cot ^4(e+f x)+\frac {8 (a-2 b) b \cot ^2(e+f x)}{a+b}+\frac {5 b^2 (4 b-3 a)}{(a+b) \left (b \tan ^2(e+f x)+a+b\right )}\right )d\tan (e+f x)}{2 b^2 (a+b)^3}-\frac {(7 a-4 b) \tan (e+f x)}{2 (a+b)^4 \left (a+b \tan ^2(e+f x)+b\right )}\right )-\frac {a b \tan (e+f x)}{4 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )^2}}{f}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\frac {1}{4} b \left (\frac {-\frac {5 b^{3/2} (3 a-4 b) \arctan \left (\frac {\sqrt {b} \tan (e+f x)}{\sqrt {a+b}}\right )}{(a+b)^{3/2}}-\frac {8 b (a-2 b) \cot (e+f x)}{a+b}-\frac {8}{3} b \cot ^3(e+f x)}{2 b^2 (a+b)^3}-\frac {(7 a-4 b) \tan (e+f x)}{2 (a+b)^4 \left (a+b \tan ^2(e+f x)+b\right )}\right )-\frac {a b \tan (e+f x)}{4 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )^2}}{f}\)

input
Int[Csc[e + f*x]^4/(a + b*Sec[e + f*x]^2)^3,x]
 
output
(-1/4*(a*b*Tan[e + f*x])/((a + b)^3*(a + b + b*Tan[e + f*x]^2)^2) + (b*((( 
-5*(3*a - 4*b)*b^(3/2)*ArcTan[(Sqrt[b]*Tan[e + f*x])/Sqrt[a + b]])/(a + b) 
^(3/2) - (8*(a - 2*b)*b*Cot[e + f*x])/(a + b) - (8*b*Cot[e + f*x]^3)/3)/(2 
*b^2*(a + b)^3) - ((7*a - 4*b)*Tan[e + f*x])/(2*(a + b)^4*(a + b + b*Tan[e 
 + f*x]^2))))/4)/f
 

3.1.65.3.1 Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

rule 361
Int[(x_)^(m_)*((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2), x_Symbol] : 
> Simp[(-a)^(m/2 - 1)*(b*c - a*d)*x*((a + b*x^2)^(p + 1)/(2*b^(m/2 + 1)*(p 
+ 1))), x] + Simp[1/(2*b^(m/2 + 1)*(p + 1))   Int[x^m*(a + b*x^2)^(p + 1)*E 
xpandToSum[2*b*(p + 1)*Together[(b^(m/2)*(c + d*x^2) - (-a)^(m/2 - 1)*(b*c 
- a*d)*x^(-m + 2))/(a + b*x^2)] - ((-a)^(m/2 - 1)*(b*c - a*d))/x^m, x], x], 
 x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0] && LtQ[p, -1] && ILtQ[m/ 
2, 0] && (IntegerQ[p] || EqQ[m + 2*p + 1, 0])
 

rule 1582
Int[(x_)^(m_)*((d_) + (e_.)*(x_)^2)^(q_)*((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^ 
4)^(p_.), x_Symbol] :> Simp[(-d)^(m/2 - 1)*(c*d^2 - b*d*e + a*e^2)^p*x*((d 
+ e*x^2)^(q + 1)/(2*e^(2*p + m/2)*(q + 1))), x] + Simp[(-d)^(m/2 - 1)/(2*e^ 
(2*p)*(q + 1))   Int[x^m*(d + e*x^2)^(q + 1)*ExpandToSum[Together[(1/(d + e 
*x^2))*(2*(-d)^(-m/2 + 1)*e^(2*p)*(q + 1)*(a + b*x^2 + c*x^4)^p - ((c*d^2 - 
 b*d*e + a*e^2)^p/(e^(m/2)*x^m))*(d + e*(2*q + 3)*x^2))], x], x], x] /; Fre 
eQ[{a, b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && IGtQ[p, 0] && ILtQ[q, -1] 
&& ILtQ[m/2, 0]
 

rule 1584
Int[((f_.)*(x_))^(m_.)*((d_) + (e_.)*(x_)^2)^(q_.)*((a_) + (b_.)*(x_)^2 + ( 
c_.)*(x_)^4)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(f*x)^m*(d + e*x^2)^q* 
(a + b*x^2 + c*x^4)^p, x], x] /; FreeQ[{a, b, c, d, e, f, m, q}, x] && NeQ[ 
b^2 - 4*a*c, 0] && IGtQ[p, 0] && IGtQ[q, -2]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4620
Int[((a_) + (b_.)*sec[(e_.) + (f_.)*(x_)]^(n_))^(p_.)*sin[(e_.) + (f_.)*(x_ 
)]^(m_), x_Symbol] :> With[{ff = FreeFactors[Tan[e + f*x], x]}, Simp[ff^(m 
+ 1)/f   Subst[Int[x^m*(ExpandToSum[a + b*(1 + ff^2*x^2)^(n/2), x]^p/(1 + f 
f^2*x^2)^(m/2 + 1)), x], x, Tan[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f, p}, 
 x] && IntegerQ[m/2] && IntegerQ[n/2]
 
3.1.65.4 Maple [A] (verified)

Time = 1.68 (sec) , antiderivative size = 140, normalized size of antiderivative = 0.85

method result size
derivativedivides \(\frac {-\frac {b \left (\frac {\left (\frac {7}{8} a b -\frac {1}{2} b^{2}\right ) \tan \left (f x +e \right )^{3}+\left (\frac {9}{8} a^{2}+\frac {5}{8} a b -\frac {1}{2} b^{2}\right ) \tan \left (f x +e \right )}{\left (a +b +b \tan \left (f x +e \right )^{2}\right )^{2}}+\frac {5 \left (3 a -4 b \right ) \arctan \left (\frac {b \tan \left (f x +e \right )}{\sqrt {\left (a +b \right ) b}}\right )}{8 \sqrt {\left (a +b \right ) b}}\right )}{\left (a +b \right )^{4}}-\frac {1}{3 \left (a +b \right )^{3} \tan \left (f x +e \right )^{3}}-\frac {a -2 b}{\left (a +b \right )^{4} \tan \left (f x +e \right )}}{f}\) \(140\)
default \(\frac {-\frac {b \left (\frac {\left (\frac {7}{8} a b -\frac {1}{2} b^{2}\right ) \tan \left (f x +e \right )^{3}+\left (\frac {9}{8} a^{2}+\frac {5}{8} a b -\frac {1}{2} b^{2}\right ) \tan \left (f x +e \right )}{\left (a +b +b \tan \left (f x +e \right )^{2}\right )^{2}}+\frac {5 \left (3 a -4 b \right ) \arctan \left (\frac {b \tan \left (f x +e \right )}{\sqrt {\left (a +b \right ) b}}\right )}{8 \sqrt {\left (a +b \right ) b}}\right )}{\left (a +b \right )^{4}}-\frac {1}{3 \left (a +b \right )^{3} \tan \left (f x +e \right )^{3}}-\frac {a -2 b}{\left (a +b \right )^{4} \tan \left (f x +e \right )}}{f}\) \(140\)
risch \(-\frac {i \left (-569 a^{3} b \,{\mathrm e}^{8 i \left (f x +e \right )}-666 a^{2} b^{2} {\mathrm e}^{8 i \left (f x +e \right )}-1704 a \,b^{3} {\mathrm e}^{8 i \left (f x +e \right )}-176 a^{4} {\mathrm e}^{8 i \left (f x +e \right )}-144 b^{4} {\mathrm e}^{6 i \left (f x +e \right )}-576 a^{3} b \,{\mathrm e}^{6 i \left (f x +e \right )}-124 a^{2} b^{2} {\mathrm e}^{6 i \left (f x +e \right )}+2184 a \,b^{3} {\mathrm e}^{6 i \left (f x +e \right )}-71 a^{3} b \,{\mathrm e}^{4 i \left (f x +e \right )}+344 a^{2} b^{2} {\mathrm e}^{4 i \left (f x +e \right )}-1208 a \,b^{3} {\mathrm e}^{4 i \left (f x +e \right )}-598 a^{2} b^{2} {\mathrm e}^{2 i \left (f x +e \right )}+48 a \,b^{3} {\mathrm e}^{2 i \left (f x +e \right )}+16 a^{4}-83 a^{3} b +6 a^{2} b^{2}-45 a^{3} b \,{\mathrm e}^{12 i \left (f x +e \right )}+60 a^{2} b^{2} {\mathrm e}^{12 i \left (f x +e \right )}-192 a^{3} b \,{\mathrm e}^{10 i \left (f x +e \right )}-558 a^{2} b^{2} {\mathrm e}^{10 i \left (f x +e \right )}+168 a \,b^{3} {\mathrm e}^{10 i \left (f x +e \right )}-48 a^{4} {\mathrm e}^{10 i \left (f x +e \right )}-48 b^{4} {\mathrm e}^{10 i \left (f x +e \right )}+144 b^{4} {\mathrm e}^{8 i \left (f x +e \right )}-224 a^{4} {\mathrm e}^{6 i \left (f x +e \right )}-96 a^{4} {\mathrm e}^{4 i \left (f x +e \right )}+48 b^{4} {\mathrm e}^{4 i \left (f x +e \right )}+16 \,{\mathrm e}^{2 i \left (f x +e \right )} a^{4}\right )}{12 a f \left (a +b \right )^{4} \left ({\mathrm e}^{2 i \left (f x +e \right )}-1\right )^{3} \left (a \,{\mathrm e}^{4 i \left (f x +e \right )}+2 a \,{\mathrm e}^{2 i \left (f x +e \right )}+4 b \,{\mathrm e}^{2 i \left (f x +e \right )}+a \right )^{2}}+\frac {15 \sqrt {-\left (a +b \right ) b}\, \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}+\frac {2 i \sqrt {-\left (a +b \right ) b}+a +2 b}{a}\right ) a}{16 \left (a +b \right )^{5} f}-\frac {5 \sqrt {-\left (a +b \right ) b}\, \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}+\frac {2 i \sqrt {-\left (a +b \right ) b}+a +2 b}{a}\right ) b}{4 \left (a +b \right )^{5} f}-\frac {15 \sqrt {-\left (a +b \right ) b}\, \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}-\frac {2 i \sqrt {-\left (a +b \right ) b}-a -2 b}{a}\right ) a}{16 \left (a +b \right )^{5} f}+\frac {5 \sqrt {-\left (a +b \right ) b}\, \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}-\frac {2 i \sqrt {-\left (a +b \right ) b}-a -2 b}{a}\right ) b}{4 \left (a +b \right )^{5} f}\) \(672\)

input
int(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^3,x,method=_RETURNVERBOSE)
 
output
1/f*(-1/(a+b)^4*b*(((7/8*a*b-1/2*b^2)*tan(f*x+e)^3+(9/8*a^2+5/8*a*b-1/2*b^ 
2)*tan(f*x+e))/(a+b+b*tan(f*x+e)^2)^2+5/8*(3*a-4*b)/((a+b)*b)^(1/2)*arctan 
(b*tan(f*x+e)/((a+b)*b)^(1/2)))-1/3/(a+b)^3/tan(f*x+e)^3-(a-2*b)/(a+b)^4/t 
an(f*x+e))
 
3.1.65.5 Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 461 vs. \(2 (148) = 296\).

Time = 0.33 (sec) , antiderivative size = 1009, normalized size of antiderivative = 6.15 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^3} \, dx=\text {Too large to display} \]

input
integrate(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^3,x, algorithm="fricas")
 
output
[-1/96*(4*(16*a^3 - 83*a^2*b + 6*a*b^2)*cos(f*x + e)^7 - 4*(24*a^3 - 134*a 
^2*b + 145*a*b^2 - 12*b^3)*cos(f*x + e)^5 - 20*(15*a^2*b - 32*a*b^2 + 16*b 
^3)*cos(f*x + e)^3 + 15*((3*a^3 - 4*a^2*b)*cos(f*x + e)^6 - (3*a^3 - 10*a^ 
2*b + 8*a*b^2)*cos(f*x + e)^4 - 3*a*b^2 + 4*b^3 - (6*a^2*b - 11*a*b^2 + 4* 
b^3)*cos(f*x + e)^2)*sqrt(-b/(a + b))*log(((a^2 + 8*a*b + 8*b^2)*cos(f*x + 
 e)^4 - 2*(3*a*b + 4*b^2)*cos(f*x + e)^2 - 4*((a^2 + 3*a*b + 2*b^2)*cos(f* 
x + e)^3 - (a*b + b^2)*cos(f*x + e))*sqrt(-b/(a + b))*sin(f*x + e) + b^2)/ 
(a^2*cos(f*x + e)^4 + 2*a*b*cos(f*x + e)^2 + b^2))*sin(f*x + e) - 60*(3*a* 
b^2 - 4*b^3)*cos(f*x + e))/(((a^6 + 4*a^5*b + 6*a^4*b^2 + 4*a^3*b^3 + a^2* 
b^4)*f*cos(f*x + e)^6 - (a^6 + 2*a^5*b - 2*a^4*b^2 - 8*a^3*b^3 - 7*a^2*b^4 
 - 2*a*b^5)*f*cos(f*x + e)^4 - (2*a^5*b + 7*a^4*b^2 + 8*a^3*b^3 + 2*a^2*b^ 
4 - 2*a*b^5 - b^6)*f*cos(f*x + e)^2 - (a^4*b^2 + 4*a^3*b^3 + 6*a^2*b^4 + 4 
*a*b^5 + b^6)*f)*sin(f*x + e)), -1/48*(2*(16*a^3 - 83*a^2*b + 6*a*b^2)*cos 
(f*x + e)^7 - 2*(24*a^3 - 134*a^2*b + 145*a*b^2 - 12*b^3)*cos(f*x + e)^5 - 
 10*(15*a^2*b - 32*a*b^2 + 16*b^3)*cos(f*x + e)^3 - 15*((3*a^3 - 4*a^2*b)* 
cos(f*x + e)^6 - (3*a^3 - 10*a^2*b + 8*a*b^2)*cos(f*x + e)^4 - 3*a*b^2 + 4 
*b^3 - (6*a^2*b - 11*a*b^2 + 4*b^3)*cos(f*x + e)^2)*sqrt(b/(a + b))*arctan 
(1/2*((a + 2*b)*cos(f*x + e)^2 - b)*sqrt(b/(a + b))/(b*cos(f*x + e)*sin(f* 
x + e)))*sin(f*x + e) - 30*(3*a*b^2 - 4*b^3)*cos(f*x + e))/(((a^6 + 4*a^5* 
b + 6*a^4*b^2 + 4*a^3*b^3 + a^2*b^4)*f*cos(f*x + e)^6 - (a^6 + 2*a^5*b ...
 
3.1.65.6 Sympy [F(-1)]

Timed out. \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^3} \, dx=\text {Timed out} \]

input
integrate(csc(f*x+e)**4/(a+b*sec(f*x+e)**2)**3,x)
 
output
Timed out
 
3.1.65.7 Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 323 vs. \(2 (148) = 296\).

Time = 0.27 (sec) , antiderivative size = 323, normalized size of antiderivative = 1.97 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^3} \, dx=-\frac {\frac {15 \, {\left (3 \, a b - 4 \, b^{2}\right )} \arctan \left (\frac {b \tan \left (f x + e\right )}{\sqrt {{\left (a + b\right )} b}}\right )}{{\left (a^{4} + 4 \, a^{3} b + 6 \, a^{2} b^{2} + 4 \, a b^{3} + b^{4}\right )} \sqrt {{\left (a + b\right )} b}} + \frac {15 \, {\left (3 \, a b^{2} - 4 \, b^{3}\right )} \tan \left (f x + e\right )^{6} + 25 \, {\left (3 \, a^{2} b - a b^{2} - 4 \, b^{3}\right )} \tan \left (f x + e\right )^{4} + 8 \, a^{3} + 24 \, a^{2} b + 24 \, a b^{2} + 8 \, b^{3} + 8 \, {\left (3 \, a^{3} + 2 \, a^{2} b - 5 \, a b^{2} - 4 \, b^{3}\right )} \tan \left (f x + e\right )^{2}}{{\left (a^{4} b^{2} + 4 \, a^{3} b^{3} + 6 \, a^{2} b^{4} + 4 \, a b^{5} + b^{6}\right )} \tan \left (f x + e\right )^{7} + 2 \, {\left (a^{5} b + 5 \, a^{4} b^{2} + 10 \, a^{3} b^{3} + 10 \, a^{2} b^{4} + 5 \, a b^{5} + b^{6}\right )} \tan \left (f x + e\right )^{5} + {\left (a^{6} + 6 \, a^{5} b + 15 \, a^{4} b^{2} + 20 \, a^{3} b^{3} + 15 \, a^{2} b^{4} + 6 \, a b^{5} + b^{6}\right )} \tan \left (f x + e\right )^{3}}}{24 \, f} \]

input
integrate(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^3,x, algorithm="maxima")
 
output
-1/24*(15*(3*a*b - 4*b^2)*arctan(b*tan(f*x + e)/sqrt((a + b)*b))/((a^4 + 4 
*a^3*b + 6*a^2*b^2 + 4*a*b^3 + b^4)*sqrt((a + b)*b)) + (15*(3*a*b^2 - 4*b^ 
3)*tan(f*x + e)^6 + 25*(3*a^2*b - a*b^2 - 4*b^3)*tan(f*x + e)^4 + 8*a^3 + 
24*a^2*b + 24*a*b^2 + 8*b^3 + 8*(3*a^3 + 2*a^2*b - 5*a*b^2 - 4*b^3)*tan(f* 
x + e)^2)/((a^4*b^2 + 4*a^3*b^3 + 6*a^2*b^4 + 4*a*b^5 + b^6)*tan(f*x + e)^ 
7 + 2*(a^5*b + 5*a^4*b^2 + 10*a^3*b^3 + 10*a^2*b^4 + 5*a*b^5 + b^6)*tan(f* 
x + e)^5 + (a^6 + 6*a^5*b + 15*a^4*b^2 + 20*a^3*b^3 + 15*a^2*b^4 + 6*a*b^5 
 + b^6)*tan(f*x + e)^3))/f
 
3.1.65.8 Giac [A] (verification not implemented)

Time = 0.42 (sec) , antiderivative size = 264, normalized size of antiderivative = 1.61 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^3} \, dx=-\frac {\frac {15 \, {\left (\pi \left \lfloor \frac {f x + e}{\pi } + \frac {1}{2} \right \rfloor \mathrm {sgn}\left (b\right ) + \arctan \left (\frac {b \tan \left (f x + e\right )}{\sqrt {a b + b^{2}}}\right )\right )} {\left (3 \, a b - 4 \, b^{2}\right )}}{{\left (a^{4} + 4 \, a^{3} b + 6 \, a^{2} b^{2} + 4 \, a b^{3} + b^{4}\right )} \sqrt {a b + b^{2}}} + \frac {3 \, {\left (7 \, a b^{2} \tan \left (f x + e\right )^{3} - 4 \, b^{3} \tan \left (f x + e\right )^{3} + 9 \, a^{2} b \tan \left (f x + e\right ) + 5 \, a b^{2} \tan \left (f x + e\right ) - 4 \, b^{3} \tan \left (f x + e\right )\right )}}{{\left (a^{4} + 4 \, a^{3} b + 6 \, a^{2} b^{2} + 4 \, a b^{3} + b^{4}\right )} {\left (b \tan \left (f x + e\right )^{2} + a + b\right )}^{2}} + \frac {8 \, {\left (3 \, a \tan \left (f x + e\right )^{2} - 6 \, b \tan \left (f x + e\right )^{2} + a + b\right )}}{{\left (a^{4} + 4 \, a^{3} b + 6 \, a^{2} b^{2} + 4 \, a b^{3} + b^{4}\right )} \tan \left (f x + e\right )^{3}}}{24 \, f} \]

input
integrate(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^3,x, algorithm="giac")
 
output
-1/24*(15*(pi*floor((f*x + e)/pi + 1/2)*sgn(b) + arctan(b*tan(f*x + e)/sqr 
t(a*b + b^2)))*(3*a*b - 4*b^2)/((a^4 + 4*a^3*b + 6*a^2*b^2 + 4*a*b^3 + b^4 
)*sqrt(a*b + b^2)) + 3*(7*a*b^2*tan(f*x + e)^3 - 4*b^3*tan(f*x + e)^3 + 9* 
a^2*b*tan(f*x + e) + 5*a*b^2*tan(f*x + e) - 4*b^3*tan(f*x + e))/((a^4 + 4* 
a^3*b + 6*a^2*b^2 + 4*a*b^3 + b^4)*(b*tan(f*x + e)^2 + a + b)^2) + 8*(3*a* 
tan(f*x + e)^2 - 6*b*tan(f*x + e)^2 + a + b)/((a^4 + 4*a^3*b + 6*a^2*b^2 + 
 4*a*b^3 + b^4)*tan(f*x + e)^3))/f
 
3.1.65.9 Mupad [B] (verification not implemented)

Time = 20.64 (sec) , antiderivative size = 207, normalized size of antiderivative = 1.26 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^3} \, dx=-\frac {\frac {1}{3\,\left (a+b\right )}+\frac {25\,{\mathrm {tan}\left (e+f\,x\right )}^4\,\left (3\,a\,b-4\,b^2\right )}{24\,{\left (a+b\right )}^3}+\frac {{\mathrm {tan}\left (e+f\,x\right )}^2\,\left (3\,a-4\,b\right )}{3\,{\left (a+b\right )}^2}+\frac {5\,{\mathrm {tan}\left (e+f\,x\right )}^6\,\left (3\,a\,b^2-4\,b^3\right )}{8\,{\left (a+b\right )}^4}}{f\,\left ({\mathrm {tan}\left (e+f\,x\right )}^3\,\left (a^2+2\,a\,b+b^2\right )+{\mathrm {tan}\left (e+f\,x\right )}^5\,\left (2\,b^2+2\,a\,b\right )+b^2\,{\mathrm {tan}\left (e+f\,x\right )}^7\right )}-\frac {5\,\sqrt {b}\,\mathrm {atan}\left (\frac {\sqrt {b}\,\mathrm {tan}\left (e+f\,x\right )\,\left (a^4+4\,a^3\,b+6\,a^2\,b^2+4\,a\,b^3+b^4\right )}{{\left (a+b\right )}^{9/2}}\right )\,\left (3\,a-4\,b\right )}{8\,f\,{\left (a+b\right )}^{9/2}} \]

input
int(1/(sin(e + f*x)^4*(a + b/cos(e + f*x)^2)^3),x)
 
output
- (1/(3*(a + b)) + (25*tan(e + f*x)^4*(3*a*b - 4*b^2))/(24*(a + b)^3) + (t 
an(e + f*x)^2*(3*a - 4*b))/(3*(a + b)^2) + (5*tan(e + f*x)^6*(3*a*b^2 - 4* 
b^3))/(8*(a + b)^4))/(f*(tan(e + f*x)^3*(2*a*b + a^2 + b^2) + tan(e + f*x) 
^5*(2*a*b + 2*b^2) + b^2*tan(e + f*x)^7)) - (5*b^(1/2)*atan((b^(1/2)*tan(e 
 + f*x)*(4*a*b^3 + 4*a^3*b + a^4 + b^4 + 6*a^2*b^2))/(a + b)^(9/2))*(3*a - 
 4*b))/(8*f*(a + b)^(9/2))